import request from '../utils/request';
import { BASE_URL } from '../utils/constant'

export function getUserList(pageNum,account){
    return request({
        url: BASE_URL + '/user/getUsers/'+pageNum+'?account='+account,
        method: 'get',
    })
}

export function editUser(user){
    return request({
        url: BASE_URL + '/user/editUser',
        method: 'post',
        data: user
    })
}

export function deleteUser(userId){
    return request({
        url: BASE_URL + '/user/deleteUser/'+userId,
        method: 'get',
    })
}

export function addUser(user){
    return request({
        url: BASE_URL + '/user/addUser',
        method: 'post',
        data: user
    })
}
